-
Notifications
You must be signed in to change notification settings - Fork 803
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
hang instead of pthread_exit during interpreter shutdown #4874
Conversation
CodSpeed Performance ReportMerging #4874 will degrade performances by 18.07%Comparing 🎉 Hooray!
|
Benchmark | BASE |
HEAD |
Change | |
---|---|---|---|---|
❌ | extract_float_downcast_fail |
396.7 ns | 484.2 ns | -18.07% |
80f138a
to
704ef0b
Compare
Yay it passes tests. |
pytests/tests/test_othermod.py
Outdated
@@ -3,7 +3,7 @@ | |||
|
|||
from pyo3_pytests import othermod | |||
|
|||
INTEGER32_ST = st.integers(min_value=(-(2**31)), max_value=(2**31 - 1)) | |||
INTEGER32_ST = st.integers(min_value=(-(2**30)), max_value=(2**30 - 1)) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this change here is to avoid the test failing due to a high rate of assume
failure (filter_too_much
).
split the test_double fix to #4879 |
any update? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This looks fine to me, but I would like at least one other maintainers opinion (maybe @davidhewitt?) before proceeding here.
Please forgive the delay, I will seek to review this on Friday, and ping me repeatedly from then if I do not achieve that! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks, I think let's move forward with this. The cfg guards hack around the various edge cases and, as I read it, the interaction with pthread_exit and rust destructors was (and still is) UB, so this just creates a practical solution for now. Ultimately 3.14 will make this problem go away.
This mimics the Python 3.14 behavior and avoids crashes in Rust 1.84.
See python/cpython#87135 and rust-lang/rust#135929 and the related pyo3-log issue vorner/pyo3-log#30
By submitting these contributions you agree for them to be dual-licensed under PyO3's MIT OR Apache-2.0 license.